// Copyright (c) 2022 Halvie Network Technology Co.,Ltd. All rights reserved.
package org.wltea.analyzer.dic;

import org.apache.logging.log4j.Logger;
import org.wltea.analyzer.help.ESPluginLoggerFactory;

/**
 * @author 🐤 xiaoyang.wang
 * @email ✉ refdust@gmail.com
 * @date ⏰ 2022/5/25 9:59 AM
 */
public class HotDictReloadThread implements Runnable {

    private static final Logger LOGGER = ESPluginLoggerFactory.getLogger(HotDictReloadThread.class.getName());
    @Override
    public void run() {
        while(true) {
            LOGGER.info("[==========]reload hot dict from mysql......");
            Dictionary.getSingleton().reLoadMainDict();
        }
    }

}
